// namesp.h
#include <string>
// create the pers and debts namespaces
namespace pers
{
    struct Person
    {
        std::string fname;
        std::string lname;
    };
    void getPerson(Person &);
    void showPerson(const Person &);
}

namespace debts
{
    //Importing a namespace using the using compiler directive adds the names of the namespace to the imported declaration region, 
    //and the potential scope of these imported names becomes the declaration region.
    using namespace pers;
    struct Debt
    {
        Person name;
        double amount;
    };
    void getDebt(Debt &);
    void showDebt(const Debt &);
    double sumDebts(const Debt ar[], int n);
    //int per_id; Variables cannot be defined in header files because header files will be included by multiple files, causing variable redefinition
}
